package com.jerry.mingxing.http;

import android.util.Log;

import com.google.gson.Gson;
import com.jerry.mingxing.bean.CategroyBean;
import com.jerry.mingxing.bean.NewBean;
import com.jerry.mingxing.config.UrlConfig;

import retrofit2.Call;
import retrofit2.Callback;
import retrofit2.Retrofit;
import retrofit2.converter.gson.GsonConverterFactory;

/**
 * Created by sHo on 16/9/1.
 */
public class HttpUtilsFashionNew {
    private HttpUtilsFashionNew(){};
    private static HttpUtilsFashionNew uutile= new HttpUtilsFashionNew();
    public static HttpUtilsFashionNew newInstance(){
        return uutile;
    }

    public void loadFashionNew(Callback<NewBean> callback){
        Retrofit retrofit = new Retrofit.Builder().baseUrl(UrlConfig.Path.BASE_URL).addConverterFactory(GsonConverterFactory.create(new Gson())).build();
        RetrofitInter retrofitInter = retrofit.create(RetrofitInter.class);
        Call<NewBean> call = retrofitInter.loadFashionNew();

        call.enqueue(callback);
    }

}
